//
//  FeedbackViewController.m
//  homeland
//
//  Created by caesar on 14-3-7.
//  Copyright (c) 2014年 xzysun. All rights reserved.
//

#import "FeedbackViewController.h"
#import <UIKit/UIKit.h>
@interface FeedbackViewController ()

@end

@implementation FeedbackViewController

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
    }
    return self;
}

- (void)viewDidLoad
{
    [super viewDidLoad];
    self.title=@"详情";
    self.name.text = _feedack.name;
    self.phone.text = _feedack.phone;
    self.comtent.text = _feedack.content;
    self.comtent.textAlignment = NSTextAlignmentLeft;
    self.time.text = _feedack.replyTime;
    self.replyContent.text = _feedack.replyContent;
    //调整高度
    CGFloat infoHeight = [self caculateHeightForString:self.comtent.text AndFontSize:14.0 AndWitdh:300];
    CGRect content = self.comtent.frame;
    content.size.height = infoHeight;
    self.comtent.frame = content;
    self.sc.contentSize = CGSizeMake(SCREEN_WIDTH, CGRectGetMaxY(content));

    
    [self.sc addSubview:self.contentView];
    //[self.view addSubview: self.sc];
    
 
    
}

- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
